package day1109;

import java.util.Scanner;

public class Test1 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        System.out.println("请输入第一个");
        String a=input.next();
        System.out.println("请输入第二个");
        String b=input.next();
        int count=0;
        for (int i=0;i<a.length();i++){
            i=a.indexOf(b,i);
            if(i==-1){
                break;
            }
            count++;
        }
        System.out.println("次数："+count);
    }
}
